package com.chandra.pos.customer.dao.entity;

/* @(#) CustomerOrderEntity.java
 * Copyright 2013 - 2015 QatarAirways Group. All Rights Reserved.
 *
 * This Software is the proprietary information of QR Group
 * Use is subject to License terms.
 * Created by T4671 on 10/04/2015.
 */

import com.chandra.pos.order.dao.entity.OrderType;

import javax.persistence.*;
import javax.validation.constraints.NotNull;


@Entity
@Table(name = "POS_CUSTOMER_ORDERS")
public class CustomerOrderEntity {

    @Id
    @GeneratedValue(strategy = GenerationType.AUTO)
    @Column(name = "CUSTOMER_ORDER_ID", unique = true, nullable = false)
    protected Long productOrderId;


    @Column(name = "CUSTOMER_ID")
    private Long customerId;

    @Column(name = "ORDER_ID", unique = true, nullable = false)
    protected Long orderId;

    @Column(name = "TOTAL_ORDER_AMOUNT", unique = false, nullable = true)
    protected Double totalOrderAmount;

    @Enumerated(EnumType.STRING)
    @NotNull
    private OrderType orderType;

    public OrderType getOrderType() {
        return orderType;
    }

    public void setOrderType(OrderType orderType) {
        this.orderType = orderType;
    }


    public Long getProductOrderId() {
        return productOrderId;
    }

    public void setProductOrderId(Long productOrderId) {
        this.productOrderId = productOrderId;
    }

    public Long getCustomerId() {
        return customerId;
    }

    public void setCustomerId(Long customerId) {
        this.customerId = customerId;
    }

    public Long getOrderId() {
        return orderId;
    }

    public void setOrderId(Long orderId) {
        this.orderId = orderId;
    }

}
